﻿using Model.BusinessModel.OutPut.sys;
using Model.BusinessModel;
using Model.DomainModel.Sys;
using Utility;
using Model.BusinessModel.OutPut;

namespace DomainService.IService.Sys
{
    /// <summary>
    /// 按钮服务接口
    /// </summary>
    public interface ISysButtonService
    {
        /// <summary>
        /// 新增按钮数据
        /// </summary>
        /// <param name="sysButton">按钮实体模型</param>
        ReceiveStatus Insert(SysButton sysButton);

        /// <summary>
        /// 修改按钮数据
        /// </summary>
        /// <param name="sysButton">按钮实体模型</param>
        ReceiveStatus Update(SysButton sysButton);

        /// <summary>
        ///  获取按钮数据
        /// </summary>
        /// <param name="pageResultModel">分页模型</param>
        /// <returns>返回按钮数据</returns>
        PageResultModel<SysButtonDataOutPut> GetButtonList(PageResultModel pageResultModel);

        /// <summary>
        /// 获取公司、系统、菜单、按钮关系数据
        /// </summary>
        /// <param name="corporationKey">公司key</param>
        /// <returns></returns>
        ReceiveStatus<TreeExtendOutPut<SysButtonDataOutPut>> GetAllButtonList(string corporationKey);

        /// <summary>
        /// 获取公司下系统菜单按钮
        /// </summary>
        /// <param name="corporationKey">公司key</param>
        /// <param name="systemKey">系统key</param>
        /// <returns></returns>
        ReceiveStatus<TreeExtendOutPut<SysButtonDataOutPut>> GetSystemMenuButtonList(string corporationKey, string systemKey);

        /// <summary>
        /// 获取菜单按钮权限
        /// </summary>
        /// <param name="userId">用户id</param>
        /// <param name="corporationKey">公司key</param>
        /// <param name="systemKey">系统key</param>
        /// <param name="menuId">菜单key</param>
        /// <param name="buttonRoleType">按钮类型</param>
        /// <returns></returns>
        ReceiveStatus<SysButtonDataOutPut> GetMenuButtonAuthList(string userId, string corporationKey, string systemKey, string menuId, int buttonRoleType);

        /// <summary>
        /// 获取菜单按钮
        /// </summary>
        /// <param name="menuId">菜单key</param>
        /// <param name="buttonRoleType">按钮类型</param>
        /// <returns></returns>
         ReceiveStatus<SysButtonDataOutPut> GetMenuButtonList(string menuId, int buttonRoleType);

    }
}
